#include "headfiles.h"

using namespace std;

bool strReplace(string &str, const string &orig, const string &changed) {
    size_t start_pos = 0;
    size_t ret_pos;
    ret_pos = str.find(orig, start_pos);
    while (ret_pos != string::npos) {
        str.replace(ret_pos, orig.size(), changed);
        start_pos = ret_pos + changed.size();
        ret_pos = str.find(orig, start_pos);
    }

    return true;
}

